#include <bits/stdc++.h>
using namespace std;
#define ll long long
#define ull unsigned long long
#define i128 __int128
#define mem(x) memset(x,0,sizeof(x))
#define endl "\n"
#define printYes cout << "Yes\n"
#define printYES cout << "YES\n"
#define printNo cout << "No\n"
#define printNO cout << "NO\n"
#define lowbit(x) ((x)&(-(x)))
#define pb push_back
#define mkp make_pair
#define pii pair<ll,ll>
#define fi first
#define se second
#define SZ(x) ((int)(x).size())
#define rep(i,j,k) for (int i=(j);i<=(k);i++)
#define per(i,j,k) for (int i=(j);i>=(k);i--)
#define pcnt(x) __builtin_popcount(x)
mt19937 rnd(time(0));
template<class T>void chkmin(T&x,T y){x=min(x,y);}
template<class T>void chkmax(T&x,T y){x=max(x,y);}

const ll inf=1000000000000000000; 
//const ll inf=1000000000;
//const ll mod=998244353;
//const ll mod=1000000007;

const int N=1000005,M=305;
int n,m,q; 
ll dis[M][M];

namespace MCMF
{
	int n,S,T;
	int h[N],nxt[N*2],t[N*2],cnt=1;
	ll w[N*2],sum,v[N*2];
	inline void add(int x,int y,int z,int zz)
	{
		t[++cnt]=y;
		w[cnt]=z,v[cnt]=zz;
		nxt[cnt]=h[x];
		h[x]=cnt;
	}
	inline void addedge(int x,int y,int z,int zz)
	{
		add(x,y,z,zz),add(y,x,0,-zz);
	}
	ll deth[N];
	int cur[N];
	queue<int>q;
	bool vis[N];
	bool bfs()
	{
		for (int i=1;i<=n;i++) deth[i]=inf,cur[i]=h[i],vis[i]=0;
		deth[S]=0,vis[S]=1;
		q.push(S);
		while (!q.empty())
		{
			int u=q.front();
			q.pop(),vis[u]=0;
			for (int i=h[u];i;i=nxt[i])
			{
				if (w[i]&&deth[t[i]]>deth[u]+v[i])
				{
					deth[t[i]]=deth[u]+v[i];
					if (vis[t[i]]==0) q.push(t[i]),vis[t[i]]=1;
				}
			}
		}
		return (deth[T]!=inf);
	}
	
	ll dfs(int u,ll dist)
	{
		if (u==T) return dist;
		ll res=0;
		vis[u]=1;
		for (int i=cur[u];i&&res<=dist;i=nxt[i])
		{
			cur[u]=i;
			if (deth[t[i]]==deth[u]+v[i]&&w[i]&&vis[t[i]]==0)
			{
				ll va=dfs(t[i],min(dist-res,w[i]));
				if (va==0) continue;
				w[i]-=va,w[i^1]+=va,sum+=va*v[i];
				res+=va;
			}
		}
		vis[u]=0;
		return res;
	}
	
	ll dinic()
	{
		ll res=0;
		while (bfs()) 
		{
			while (ll ans=dfs(S,inf)) res+=ans;
		}
		return res;
	}	
	
	void init(int _n,int _S,int _T)
	{
		n=_n,S=_S,T=_T;
		cnt=1;
		rep(i,1,n) h[i]=0;
		sum=0;
	}
	
	void update()
	{
		w[2]++;
	}
	
	pii work()
	{
		ll res=dinic();
		return mkp(res,sum);
	}
}
ll d[N];

int main()
{
	freopen("journey.in","r",stdin);
	freopen("journey.out","w",stdout);
	ios_base::sync_with_stdio(false);
	cin.tie(0);cout.tie(0);
	cin >> n >> m >> q;
	int S=2*n+2,T=2*n+3;
	MCMF::init(T,S,T);
	MCMF::addedge(S,S-1,0,0);
	rep(i,1,n) rep(j,1,n) dis[i][j]=inf;
	rep(i,1,n) dis[i][i]=0;
	rep(i,1,m)
	{
		ll x,y,z;
		cin >> x >> y >> z;
		chkmin(dis[x][y],z);
	}
	rep(k,1,n) rep(i,1,n) rep(j,1,n) chkmin(dis[i][j],dis[i][k]+dis[k][j]);
	rep(i,1,n) rep(j,1,n)
	{
		if (i==j) continue;
		if (dis[i][j]==inf) continue;
		MCMF::addedge(i,n+j,1,dis[i][j]);
	}
	rep(i,1,n) MCMF::addedge(S-1,i,1,0);
	rep(i,1,n) MCMF::addedge(i+n,T,1,0);
	rep(i,1,n)
	{
		MCMF::update();
		pii res=MCMF::work();
		if (res.fi==1) d[i]=res.se;
		else d[i]=inf;
	}
	rep(i,1,q)
	{
		ll x;
		cin >> x;
		ll ans=inf;
		rep(j,0,n) chkmin(ans,d[j]+(n-j)*x);
		cout << ans <<endl;
	}
	// rep(i,1,n) cout << d[i] << " ";
	// cout << endl;
	return 0;
}
